package actionPattern.RespsbilityChain.model;

public class Leader implements IManager{
    @Override
    public boolean approve(LeaveRequest leaveRequest) {

        //主管审批员工离职是否提前沟通
        if(!leaveRequest.isPreCommunicated()) {
            System.out.println("该员工离职未提前与leader沟通，主管审批拒绝");
            return false;
        }
        System.out.println("主管审批通过");
        return true;
    }

}
